import React from 'react'
import { NavLink, Outlet } from 'react-router-dom'
import '../index.css'

export default function Home() {
  return (
    <div>
      <h2>我是Home的内容</h2>
      <div>
        <ul className='nav nav-tabs'>
          <li className='nav-item'>
            <NavLink className='nav-link' to="news">News</NavLink>
          </li>
          <li className='nav-item'>
            <NavLink className='nav-link' to="/home/message">Message</NavLink>
          </li>
        </ul>
        {/* 指定路由组件呈现的位置 */}
        <Outlet></Outlet>
      </div>
    </div>
  )
}
